<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <title>CSS Writing Modes Test: vertical alignment - 'top' property (vertical-lr)</title>
    <link rel="author" title="Hajime Shiozawa" href="mailto:hajime.shiozawa@gmail.com" />
    <link rel="help" title="4.4. Baseline Alignment" href="http://www.w3.org/TR/css3-writing-modes/#baseline-alignment" />
    <meta name="assert" content="This test checks the generation of text baseline with vertical align property." />
    <meta name="flags" content="image" />
    <style type="text/css"><![CDATA[
      div > p {
        line-height: 2em;
        font-family: "Ahem";
        font-size: 25px;
        background-color: orange;
      }

      /* vertical-align */
      img {
        vertical-align: top;
      }
      img.box {
        margin-top: -50px;
      }
      img.line {
        margin-top: -210px;
      }

      /* writing-mode property */
      .vertical-lr {
        writing-mode: vertical-lr;
        -webkit-writing-mode: vertical-lr;
      }

      /* text-orientation property */
      .mixed {
        text-orientation: mixed;
        -webkit-text-orientation: mixed;
      }
      .upright {
        text-orientation: upright;
        -webkit-text-orientation: upright;
      }
      .sideways-right {
        text-orientation: sideways-right;
        -webkit-text-orientation: sideways-right;
      }
      .sideways-left {
        text-orientation: sideways-left;
        -webkit-text-orientation: sideways-left;
      }
      .sideways {
        text-orientation: sideways;
        -webkit-text-orientation: sideways;
      }
      .use-glyph-orientation {
        text-orientation: use-glyph-orientation;
      }
  ]]></style>
  </head>
  <body>
    <p>Test passes if a thin blue line is aligned to the <strong>left</strong> of orange rectangles,
      if the <strong>left</strong> margin edge of yellow box is aligned to the <strong>left</strong> of orange rectangles
      and if all 4 orange rectangles are <strong>identical</strong>.</p>

    <div class="vertical-lr">
      <p class="mixed"><span>TOP.TOP.
        <img class="line" src="./support/blue-vert-line_1x220.png" alt="Image download support must be enabled" />
        <img class="box" src="./support/vert-box_59x59.png" alt="Image download support must be enabled" /></span>
      </p>
      <p class="upright"><span>TOP.TOP.
        <img class="line" src="./support/blue-vert-line_1x220.png" alt="Image download support must be enabled" />
        <img class="box" src="./support/vert-box_59x59.png" alt="Image download support must be enabled" /></span>
      </p>
      <p class="sideways-right"><span>TOP.TOP.
        <img class="line" src="./support/blue-vert-line_1x220.png" alt="Image download support must be enabled" />
        <img class="box" src="./support/vert-box_59x59.png" alt="Image download support must be enabled" /></span>
      </p>
      <p class="sideways-left"><span>TOP.TOP.
        <img class="line" src="./support/blue-vert-line_1x220.png" alt="Image download support must be enabled" />
        <img class="box" src="./support/vert-box_59x59.png" alt="Image download support must be enabled" /></span>
      </p>
      <p class="sideways"><span>TOP.TOP.
        <img class="line" src="./support/blue-vert-line_1x220.png" alt="Image download support must be enabled" />
        <img class="box" src="./support/vert-box_59x59.png" alt="Image download support must be enabled" /></span>
      </p>
      <p class="use-glyph-orientation"><span>TOP.TOP.
        <img class="line" src="./support/blue-vert-line_1x220.png" alt="Image download support must be enabled" />
        <img class="box" src="./support/vert-box_59x59.png" alt="Image download support must be enabled" /></span>
      </p>
    </div>
  </body>
</html>
